import styled, {createGlobalStyle} from 'styled-components';
import {
    DeepBackgroundColor,
    LightBackgroundColor,
    LightFontColor,
    StrongBackgroundColor,
    SuperLightBackgroundColor,
    SuperLightFontColor
} from "@/style/Color";
/* Reset.css 全局初始化样式*/
export const GlobalStyle = createGlobalStyle`
  html, body, div, span, applet, object, iframe, p, blockquote, pre,
  a, abbr, acronym, address, big, cite, code,
  del, dfn, em, img, ins, kbd, q, s, samp,
  small, strike, strong, sub, sup, tt, var,
  b, u, i, center,
  dl, dt, dd, ol, ul, li,
  fieldset, form, label, legend,
  table, caption, tbody, tfoot, thead, tr, th, td,
  article, aside, canvas, details, embed,
  figure, figcaption, footer, header, hgroup,
  menu, nav, output, ruby, section, summary,
  time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
  }


  .icon {
    width: 1em;
    height: 1em;
    vertical-align: -0.15em;
    fill: currentColor;
    overflow: hidden;
  }

  /* HTML5 display-role reset for older browsers */
  article, aside, details, figcaption, figure,
  footer, header, hgroup, menu, nav, section {
    display: block;
  }

  body {
    line-height: 1;
    background-color: ${DeepBackgroundColor};
  }

  /* 滚动条 */
  body::-webkit-scrollbar {
    /*滚动条整体样式*/
    width: 5px; /*高宽分别对应横竖滚动条的尺寸*/
    height: 0px;
  }

  /* 滚动条 */
  body::-webkit-scrollbar-thumb {
    /*滚动条里面小方块*/
    background-color: #8ebace;
    border-radius: 10px;

    &:hover {
      background-color: #3eaad7;
    }
  }

  /* 滚动条 */
  body::-webkit-scrollbar-track {
    /*滚动条里面轨道*/
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    background: #dcdcdc;
    border-radius: 10px;
  }

  /* 选择文本后的背景颜色 */
  ::selection {
    background:  ${SuperLightFontColor};
    //color: inherit !important;
    color: #535353 !important;
  }

  /* 选择文本后的背景颜色 */
  ::-moz-selection {
    background:  ${SuperLightFontColor};
    //color: inherit !important;
    color: #535353 !important;
  }

  ol, ul {
    list-style: none;
  }

  blockquote, q {
    quotes: none;
  }

  blockquote:before,
  blockquote:after,
  q:before, q:after {
    content: none;
  }

  table {
    border-collapse: collapse;
    border-spacing: 0;
  }

  /* 底部组件共同写法 不采用单独封装 */
  .footer {
    //margin-top: 20px;
    float: left;
    width: 100%;
    background: ${StrongBackgroundColor};
    text-align: center;
    font-size: 12px;
    padding: 50px 10px;
    line-height: 20px;
    transition: .2s ease-in-out;
  }

  .ant-collapse-content {
    background-color: rgba(255, 255, 255, 0.7);
  }

  .ant-input-textarea-show-count::after {
    color: ${LightFontColor};
  }

  //修改表头文字、背景颜色  
  .ant-table-thead > tr > th {
    color: white;
    background: ${LightBackgroundColor} !important;
  }

  .ant-input:-webkit-autofill {
    box-shadow: 0 0 0 1000px #f3f3f3 inset;
  }

  .ant-input:hover, input:focus {
    box-shadow: 0 0 0 1000px #f3f3f3 inset;
  }

  .ant-empty-description {
    color: ${LightFontColor};
  }

  .ant-input {
    background: rgba(255, 255, 255, 0.4);
  }

  .ant-pagination-total-text {
    color: ${LightFontColor} !important;
  }

  .ant-pagination-disabled .ant-pagination-item-link,
  .ant-pagination-disabled:hover .ant-pagination-item-link,
  .ant-pagination-disabled:focus-visible .ant-pagination-item-link {
    color: rgba(255, 255, 255, 0.75);
  }

  //修改列表文字、背景颜色  
  .ant-table-tbody > tr > th {
    color: white;
    background: ${LightBackgroundColor} !important;
  }

  .ant-table {
    background: ${SuperLightBackgroundColor} !important;
    color: white;

  }

  .ant-table table {
    border-bottom: 1px solid ${LightFontColor};
  }

  .ant-btn {
    border: none;
  }

  //在鼠标悬浮时背景色展示在当前项非当前行
  .ant-table-tbody > tr > td {
    border-bottom: none;
    background: rgba(255, 255, 255, 0) !important;
  }

  .ant-table-tbody > tr > td:hover {
    background: rgb(255, 255, 255) !important;
  }

  //去除鼠标悬浮的背景色  
  .ant-table-tbody > tr > td {
    background: rgba(255, 255, 255, 0) !important;
  }

  .ant-table-tbody > tr > td:hover {
    background: rgba(255, 255, 255, 0) !important;
  }

  .ant-table-tbody .ant-table-cell-fix-right {
    background: ${SuperLightBackgroundColor} !important;
    color: white;
  }

  .footer a:link {
    color: ${LightFontColor};

  }

  .footer a:visited {
    color: ${LightFontColor};
  }

  .footer a:hover {
    color: #3697ff;
  }

  .footer a:active {
    color: ${LightFontColor};
  }

  .footer, .footer > p, .footer a {
    color: ${LightFontColor};
    text-decoration: none;

  }

  .footer > p {
    margin: 5px auto 10px;
  }

  .footer > a > img {
    height: 20px;
    margin-right: 4px;
  }


  /* 旁门正道标题体2 */
  @font-face {
    font-family: 'pangmenzhengdao';
    font-display: swap;
    src: url('//at.alicdn.com/t/webfont_136uqwkq06dd.eot'); /* IE9*/
    src: url('//at.alicdn.com/t/webfont_136uqwkq06dd.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ url('//at.alicdn.com/t/webfont_136uqwkq06dd.woff2') format('woff2'),
    url('//at.alicdn.com/t/webfont_136uqwkq06dd.woff') format('woff'), /* chrome、firefox */ url('//at.alicdn.com/t/webfont_136uqwkq06dd.ttf') format('truetype'), /* chrome、firefox、opera、Safari, Android, iOS 4.2+*/ url('//at.alicdn.com/t/webfont_136uqwkq06dd.svg#庞门正道标题体2') format('svg'); /* iOS 4.1- */
  }

  @font-face {
    font-family: 'kuhei';
    font-display: swap;
    src: url('//at.alicdn.com/t/webfont_nutbra2a3fr.eot'); /* IE9*/
    src: url('//at.alicdn.com/t/webfont_nutbra2a3fr.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ url('//at.alicdn.com/t/webfont_nutbra2a3fr.woff2') format('woff2'),
    url('//at.alicdn.com/t/webfont_nutbra2a3fr.woff') format('woff'), /* chrome、firefox */ url('//at.alicdn.com/t/webfont_nutbra2a3fr.ttf') format('truetype'), /* chrome、firefox、opera、Safari, Android, iOS 4.2+*/ url('//at.alicdn.com/t/webfont_nutbra2a3fr.svg#站酷高端黑') format('svg'); /* iOS 4.1- */
  }
`
export const ShadowTriangle = styled.div`
  width: 0;
  height: 0;
  position: absolute;
  z-index: 0;
  border: 25px solid #000000;
  border-top-left-radius: 10px;
  border-bottom-color: transparent;
  border-right-color: transparent;
  opacity: 0.25;

`
